package com.gitee.freakchicken.dbapi.basic.controller;

import com.gitee.freakchicken.dbapi.basic.domain.Client;
import com.gitee.freakchicken.dbapi.basic.service.C_J7fvfApj;
import com.gitee.freakchicken.dbapi.basic.util.C_3CjyYmwF;
import com.gitee.freakchicken.dbapi.common.ResponseDto;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import java.util.List;

@RestController
@RequestMapping("/client")
public class C_iI4nVkF0 {

    @Autowired
    private C_J7fvfApj gf_dz3lTk7n;

    @PostMapping("/create")
    public ResponseDto m_1JUA5pj9(Client client) {
        client.setCreateUserId(C_3CjyYmwF.m_j3EEUXak());
        return gf_dz3lTk7n.m_koXECXnW(client);
    }

    @PostMapping("/getAll")
    public List<Client> m_Wf3vio2E() {
        List<Client> lf_0DBXQkoI = gf_dz3lTk7n.m_WL8ARU2n();
        return lf_0DBXQkoI;
    }

    @PostMapping("/delete/{clientId}")
    public void m_kFqBasYQ(@PathVariable("clientId") String clientId) {
        gf_dz3lTk7n.m_Q8mHI1vv(clientId);
    }

    @PostMapping("/auth")
    public void m_DgNCyOna(String clientId, String groupIds) {
        gf_dz3lTk7n.m_9kixRUSz(clientId, groupIds);
    }

    @PostMapping("/getAuthGroups/{clientId}")
    public List<String> m_8DLG3gzU(@PathVariable("clientId") String clientId) {
        return gf_dz3lTk7n.m_7k74tiGm(clientId);
    }
}
